<?php

namespace app\crm\model;

use app\admin\model\ShopModel;
use think\facade\Db;
use app\common\traits\ActionRecordTrait;
use think\Model;
use app\admin\controller\ApiCommon;
use app\mini\model\PersonCase;

class Coupon extends Model
{
    use ActionRecordTrait;

    /**
     * 表名
     * @var string
     */
    protected $name = 'coupon';

    public function customer()
    {
        return $this->hasOne(Customer::class, 'id', 'customer_id');
    }

    public function shop()
    {
        return $this->hasOne(ShopModel::class, 'shop_id', 'shop_id');
    }



}
